.class public Les/wx;
.super Landroid/widget/RelativeLayout;
.source "FeedbackRatingView.java"


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Les/wx$f;
    }
.end annotation


# instance fields
.field private a:Landroid/content/Context;

.field private b:Landroid/widget/Button;

.field private c:Landroid/widget/RatingBar;

.field private d:Landroid/view/View$OnClickListener;

.field private e:Landroid/view/View$OnClickListener;

.field private f:Landroid/widget/ImageView;

.field private g:Landroid/widget/ImageView;

.field private h:Landroid/view/animation/TranslateAnimation;

.field private i:Z


# direct methods
.method public constructor <init>(Landroid/content/Context;)V
    .locals 1

    const/4 v0, 0x0

    .line 4
    invoke-direct {p0, p1, v0}, Les/wx;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V

    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
    .locals 0

    .line 1
    invoke-direct {p0, p1, p2}, Landroid/widget/RelativeLayout;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V

    const/4 p2, 0x0

    .line 2
    iput-boolean p2, p0, Les/wx;->i:Z

    .line 3
    invoke-direct {p0, p1}, Les/wx;->a(Landroid/content/Context;)V

    return-void
.end method

.method private a(Landroid/content/Context;)V
    .locals 2

    .line 2
    iput-object p1, p0, Les/wx;->a:Landroid/content/Context;

    const v0, 0x7f0c015b

    .line 3
    invoke-static {p1, v0, p0}, Landroid/widget/RelativeLayout;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;

    const p1, 0x7f090418

    .line 4
    invoke-virtual {p0, p1}, Landroid/widget/RelativeLayout;->findViewById(I)Landroid/view/View;

    move-result-object p1

    check-cast p1, Landroid/widget/Button;

    iput-object p1, p0, Les/wx;->b:Landroid/widget/Button;

    const p1, 0x7f09041d

    .line 5
    invoke-virtual {p0, p1}, Landroid/widget/RelativeLayout;->findViewById(I)Landroid/view/View;

    move-result-object p1

    check-cast p1, Landroid/widget/RatingBar;

    iput-object p1, p0, Les/wx;->c:Landroid/widget/RatingBar;

    .line 6
    iget-object p1, p0, Les/wx;->b:Landroid/widget/Button;

    const/4 v0, 0x0

    invoke-virtual {p1, v0}, Landroid/widget/Button;->setEnabled(Z)V

    .line 7
    iget-object p1, p0, Les/wx;->b:Landroid/widget/Button;

    iget-object v0, p0, Les/wx;->a:Landroid/content/Context;

    const v1, 0x7f11043d

    invoke-virtual {v0, v1}, Landroid/content/Context;->getString(I)Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    const p1, 0x7f09041c

    .line 8
    invoke-virtual {p0, p1}, Landroid/widget/RelativeLayout;->findViewById(I)Landroid/view/View;

    move-result-object p1

    check-cast p1, Landroid/widget/ImageView;

    iput-object p1, p0, Les/wx;->f:Landroid/widget/ImageView;

    .line 9
    new-instance v0, Les/wx$a;

    invoke-direct {v0, p0}, Les/wx$a;-><init>(Les/wx;)V

    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->post(Ljava/lang/Runnable;)Z

    const p1, 0x7f090419

    .line 10
    invoke-virtual {p0, p1}, Landroid/widget/RelativeLayout;->findViewById(I)Landroid/view/View;

    move-result-object p1

    check-cast p1, Landroid/widget/ImageView;

    iput-object p1, p0, Les/wx;->g:Landroid/widget/ImageView;

    .line 11
    iget-object p1, p0, Les/wx;->c:Landroid/widget/RatingBar;

    new-instance v0, Les/wx$b;

    invoke-direct {v0, p0}, Les/wx$b;-><init>(Les/wx;)V

    invoke-virtual {p1, v0}, Landroid/widget/RatingBar;->setOnRatingBarChangeListener(Landroid/widget/RatingBar$OnRatingBarChangeListener;)V

    .line 12
    iget-object p1, p0, Les/wx;->b:Landroid/widget/Button;

    new-instance v0, Les/wx$c;

    invoke-direct {v0, p0}, Les/wx$c;-><init>(Les/wx;)V

    invoke-virtual {p1, v0}, Landroid/widget/Button;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    .line 13
    iget-object p1, p0, Les/wx;->g:Landroid/widget/ImageView;

    new-instance v0, Les/wx$d;

    invoke-direct {v0, p0}, Les/wx$d;-><init>(Les/wx;)V

    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    return-void
.end method

.method static synthetic a(Les/wx;)V
    .locals 0

    .line 1
    invoke-direct {p0}, Les/wx;->b()V

    return-void
.end method

.method static synthetic b(Les/wx;)Landroid/widget/Button;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->b:Landroid/widget/Button;

    return-object p0
.end method

.method private b()V
    .locals 8

    .line 2
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    const/4 v1, 0x1

    if-nez v0, :cond_0

    .line 3
    invoke-virtual {p0}, Landroid/widget/RelativeLayout;->getMeasuredWidth()I

    move-result v0

    int-to-float v0, v0

    .line 4
    invoke-virtual {p0}, Landroid/widget/RelativeLayout;->getMeasuredHeight()I

    move-result v2

    int-to-float v2, v2

    .line 5
    iget-object v3, p0, Les/wx;->f:Landroid/widget/ImageView;

    invoke-virtual {v3}, Landroid/widget/ImageView;->getMeasuredWidth()I

    move-result v3

    int-to-float v3, v3

    .line 6
    iget-object v4, p0, Les/wx;->f:Landroid/widget/ImageView;

    invoke-virtual {v4}, Landroid/widget/ImageView;->getMeasuredHeight()I

    move-result v4

    int-to-float v4, v4

    .line 7
    iget-object v5, p0, Les/wx;->c:Landroid/widget/RatingBar;

    invoke-static {v5}, Landroidx/core/view/ViewCompat;->getX(Landroid/view/View;)F

    move-result v5

    iget-object v6, p0, Les/wx;->c:Landroid/widget/RatingBar;

    invoke-virtual {v6}, Landroid/widget/RatingBar;->getMeasuredWidth()I

    move-result v6

    int-to-float v6, v6

    const/high16 v7, 0x40800000    # 4.0f

    mul-float v6, v6, v7

    const/high16 v7, 0x40a00000    # 5.0f

    div-float/2addr v6, v7

    add-float/2addr v5, v6

    const/high16 v6, 0x40000000    # 2.0f

    div-float/2addr v3, v6

    add-float/2addr v5, v3

    .line 8
    iget-object v3, p0, Les/wx;->c:Landroid/widget/RatingBar;

    invoke-static {v3}, Landroidx/core/view/ViewCompat;->getY(Landroid/view/View;)F

    move-result v3

    const/high16 v6, 0x40400000    # 3.0f

    div-float/2addr v4, v6

    add-float/2addr v3, v4

    .line 9
    new-instance v4, Landroid/view/animation/TranslateAnimation;

    invoke-direct {v4, v0, v5, v2, v3}, Landroid/view/animation/TranslateAnimation;-><init>(FFFF)V

    iput-object v4, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    const-wide/16 v2, 0x5dc

    .line 10
    invoke-virtual {v4, v2, v3}, Landroid/view/animation/TranslateAnimation;->setDuration(J)V

    .line 11
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    invoke-virtual {v0, v1}, Landroid/view/animation/TranslateAnimation;->setRepeatMode(I)V

    .line 12
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    const/4 v2, -0x1

    invoke-virtual {v0, v2}, Landroid/view/animation/TranslateAnimation;->setRepeatCount(I)V

    .line 13
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    new-instance v2, Les/wx$e;

    invoke-direct {v2, p0}, Les/wx$e;-><init>(Les/wx;)V

    invoke-virtual {v0, v2}, Landroid/view/animation/TranslateAnimation;->setAnimationListener(Landroid/view/animation/Animation$AnimationListener;)V

    .line 14
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    new-instance v2, Les/wx$f;

    const/4 v3, 0x0

    invoke-direct {v2, p0, v3}, Les/wx$f;-><init>(Les/wx;Les/wx$a;)V

    invoke-virtual {v0, v2}, Landroid/view/animation/TranslateAnimation;->setInterpolator(Landroid/view/animation/Interpolator;)V

    .line 15
    :cond_0
    iget-object v0, p0, Les/wx;->f:Landroid/widget/ImageView;

    iget-object v2, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    invoke-virtual {v0, v2}, Landroid/widget/ImageView;->setAnimation(Landroid/view/animation/Animation;)V

    .line 16
    iput-boolean v1, p0, Les/wx;->i:Z

    .line 17
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    invoke-virtual {v0}, Landroid/view/animation/TranslateAnimation;->startNow()V

    return-void
.end method

.method static synthetic c(Les/wx;)Landroid/content/Context;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->a:Landroid/content/Context;

    return-object p0
.end method

.method static synthetic d(Les/wx;)Landroid/widget/RatingBar;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->c:Landroid/widget/RatingBar;

    return-object p0
.end method

.method static synthetic e(Les/wx;)Landroid/view/View$OnClickListener;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->d:Landroid/view/View$OnClickListener;

    return-object p0
.end method

.method static synthetic f(Les/wx;)Landroid/view/View$OnClickListener;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->e:Landroid/view/View$OnClickListener;

    return-object p0
.end method

.method static synthetic g(Les/wx;)Z
    .locals 0

    .line 1
    iget-boolean p0, p0, Les/wx;->i:Z

    return p0
.end method

.method static synthetic h(Les/wx;)Landroid/widget/ImageView;
    .locals 0

    .line 1
    iget-object p0, p0, Les/wx;->f:Landroid/widget/ImageView;

    return-object p0
.end method


# virtual methods
.method public a()V
    .locals 2

    const/4 v0, 0x0

    .line 14
    iput-boolean v0, p0, Les/wx;->i:Z

    .line 15
    iget-object v0, p0, Les/wx;->h:Landroid/view/animation/TranslateAnimation;

    if-eqz v0, :cond_0

    .line 16
    invoke-virtual {v0}, Landroid/view/animation/TranslateAnimation;->cancel()V

    .line 17
    :cond_0
    iget-object v0, p0, Les/wx;->f:Landroid/widget/ImageView;

    invoke-virtual {v0}, Landroid/widget/ImageView;->clearAnimation()V

    .line 18
    iget-object v0, p0, Les/wx;->f:Landroid/widget/ImageView;

    const/16 v1, 0x8

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V

    return-void
.end method

.method public setOnClickedListener(Landroid/view/View$OnClickListener;)V
    .locals 0

    .line 1
    iput-object p1, p0, Les/wx;->d:Landroid/view/View$OnClickListener;

    return-void
.end method

.method public setOnCloseListener(Landroid/view/View$OnClickListener;)V
    .locals 0

    .line 1
    iput-object p1, p0, Les/wx;->e:Landroid/view/View$OnClickListener;

    return-void
.end method
